Optimal. Leaf size=156 \[ -\frac {(4+4 i) a^{5/2} \tanh ^{-1}\left (\frac {(1+i) \sqrt {a} \sqrt {\tan (c+d x)}}{\sqrt {a+i a \tan (c+d x)}}\right )}{d}+\frac {4 a^2 \sqrt {a+i a \tan (c+d x)}}{d \sqrt {\tan (c+d x)}}-\frac {2 i a (a+i a \tan (c+d x))^{3/2}}{3 d \tan ^{\frac {3}{2}}(c+d x)}-\frac {2 (a+i a \tan (c+d x))^{5/2}}{5 d \tan ^{\frac {5}{2}}(c+d x)} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.18, antiderivative size = 156, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 4, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3629, 3626,
3625, 211} \begin {gather*} -\frac {(4+4 i) a^{5/2} \tanh ^{-1}\left (\frac {(1+i) \sqrt {a} \sqrt {\tan (c+d x)}}{\sqrt {a+i a \tan (c+d x)}}\right )}{d}+\frac {4 a^2 \sqrt {a+i a \tan (c+d x)}}{d \sqrt {\tan (c+d x)}}-\frac {2 i a (a+i a \tan (c+d x))^{3/2}}{3 d \tan ^{\frac {3}{2}}(c+d x)}-\frac {2 (a+i a \tan (c+d x))^{5/2}}{5 d \tan ^{\frac {5}{2}}(c+d x)} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 211
Rule 3625
Rule 3626
Rule 3629
Rubi steps
\begin {align*} \int \frac {(a+i a \tan (c+d x))^{5/2}}{\tan ^{\frac {7}{2}}(c+d x)} \, dx &=-\frac {2 (a+i a \tan (c+d x))^{5/2}}{5 d \tan ^{\frac {5}{2}}(c+d x)}+i \int \frac {(a+i a \tan (c+d x))^{5/2}}{\tan ^{\frac {5}{2}}(c+d x)} \, dx\\ &=-\frac {2 i a (a+i a \tan (c+d x))^{3/2}}{3 d \tan ^{\frac {3}{2}}(c+d x)}-\frac {2 (a+i a \tan (c+d x))^{5/2}}{5 d \tan ^{\frac {5}{2}}(c+d x)}-(2 a) \int \frac {(a+i a \tan (c+d x))^{3/2}}{\tan ^{\frac {3}{2}}(c+d x)} \, dx\\ &=\frac {4 a^2 \sqrt {a+i a \tan (c+d x)}}{d \sqrt {\tan (c+d x)}}-\frac {2 i a (a+i a \tan (c+d x))^{3/2}}{3 d \tan ^{\frac {3}{2}}(c+d x)}-\frac {2 (a+i a \tan (c+d x))^{5/2}}{5 d \tan ^{\frac {5}{2}}(c+d x)}-\left (4 i a^2\right ) \int \frac {\sqrt {a+i a \tan (c+d x)}}{\sqrt {\tan (c+d x)}} \, dx\\ &=\frac {4 a^2 \sqrt {a+i a \tan (c+d x)}}{d \sqrt {\tan (c+d x)}}-\frac {2 i a (a+i a \tan (c+d x))^{3/2}}{3 d \tan ^{\frac {3}{2}}(c+d x)}-\frac {2 (a+i a \tan (c+d x))^{5/2}}{5 d \tan ^{\frac {5}{2}}(c+d x)}-\frac {\left (8 a^4\right ) \text {Subst}\left (\int \frac {1}{-i a-2 a^2 x^2} \, dx,x,\frac {\sqrt {\tan (c+d x)}}{\sqrt {a+i a \tan (c+d x)}}\right )}{d}\\ &=-\frac {(4+4 i) a^{5/2} \tanh ^{-1}\left (\frac {(1+i) \sqrt {a} \sqrt {\tan (c+d x)}}{\sqrt {a+i a \tan (c+d x)}}\right )}{d}+\frac {4 a^2 \sqrt {a+i a \tan (c+d x)}}{d \sqrt {\tan (c+d x)}}-\frac {2 i a (a+i a \tan (c+d x))^{3/2}}{3 d \tan ^{\frac {3}{2}}(c+d x)}-\frac {2 (a+i a \tan (c+d x))^{5/2}}{5 d \tan ^{\frac {5}{2}}(c+d x)}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 3.72, size = 187, normalized size = 1.20 \begin {gather*} -\frac {4 i a^2 e^{-i (c+d x)} \left (e^{i (c+d x)} \left (15-35 e^{2 i (c+d x)}+26 e^{4 i (c+d x)}\right )-15 \left (-1+e^{2 i (c+d x)}\right )^{5/2} \tanh ^{-1}\left (\frac {e^{i (c+d x)}}{\sqrt {-1+e^{2 i (c+d x)}}}\right )\right ) \cot (c+d x) \sqrt {a+i a \tan (c+d x)}}{15 d \sqrt {-\frac {i \left (-1+e^{2 i (c+d x)}\right )}{1+e^{2 i (c+d x)}}} \left (-1+e^{4 i (c+d x)}\right )} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Both result and optimal contain complex but leaf count of result is larger than twice
the leaf count of optimal. 413 vs. \(2 (127 ) = 254\).
time = 0.17, size = 414, normalized size = 2.65
method | result | size |
derivativedivides | \(\frac {\sqrt {a \left (1+i \tan \left (d x +c \right )\right )}\, a^{2} \left (15 i \sqrt {i a}\, \sqrt {2}\, \ln \left (-\frac {-2 \sqrt {2}\, \sqrt {-i a}\, \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}+i a -3 a \tan \left (d x +c \right )}{\tan \left (d x +c \right )+i}\right ) a \left (\tan ^{3}\left (d x +c \right )\right )+15 \sqrt {i a}\, \sqrt {2}\, \ln \left (-\frac {-2 \sqrt {2}\, \sqrt {-i a}\, \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}+i a -3 a \tan \left (d x +c \right )}{\tan \left (d x +c \right )+i}\right ) a \left (\tan ^{3}\left (d x +c \right )\right )+76 \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}\, \left (\tan ^{2}\left (d x +c \right )\right )+60 \ln \left (\frac {2 i a \tan \left (d x +c \right )+2 \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}+a}{2 \sqrt {i a}}\right ) \sqrt {-i a}\, a \left (\tan ^{3}\left (d x +c \right )\right )-22 i \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}\, \tan \left (d x +c \right )-6 \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}\right )}{15 d \tan \left (d x +c \right )^{\frac {5}{2}} \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}}\) | \(414\) |
default | \(\frac {\sqrt {a \left (1+i \tan \left (d x +c \right )\right )}\, a^{2} \left (15 i \sqrt {i a}\, \sqrt {2}\, \ln \left (-\frac {-2 \sqrt {2}\, \sqrt {-i a}\, \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}+i a -3 a \tan \left (d x +c \right )}{\tan \left (d x +c \right )+i}\right ) a \left (\tan ^{3}\left (d x +c \right )\right )+15 \sqrt {i a}\, \sqrt {2}\, \ln \left (-\frac {-2 \sqrt {2}\, \sqrt {-i a}\, \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}+i a -3 a \tan \left (d x +c \right )}{\tan \left (d x +c \right )+i}\right ) a \left (\tan ^{3}\left (d x +c \right )\right )+76 \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}\, \left (\tan ^{2}\left (d x +c \right )\right )+60 \ln \left (\frac {2 i a \tan \left (d x +c \right )+2 \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}+a}{2 \sqrt {i a}}\right ) \sqrt {-i a}\, a \left (\tan ^{3}\left (d x +c \right )\right )-22 i \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}\, \tan \left (d x +c \right )-6 \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}\right )}{15 d \tan \left (d x +c \right )^{\frac {5}{2}} \sqrt {a \tan \left (d x +c \right ) \left (1+i \tan \left (d x +c \right )\right )}\, \sqrt {i a}\, \sqrt {-i a}}\) | \(414\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Both result and optimal contain complex but leaf count of result is larger than
twice the leaf count of optimal. 1284 vs. \(2 (118) = 236\).
time = 0.68, size = 1284, normalized size = 8.23 \begin {gather*} \text {Too large to display} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Both result and optimal contain complex but leaf count of result is larger than twice
the leaf count of optimal. 466 vs. \(2 (118) = 236\).
time = 0.39, size = 466, normalized size = 2.99 \begin {gather*} -\frac {8 \, \sqrt {2} {\left (-26 i \, a^{2} e^{\left (7 i \, d x + 7 i \, c\right )} + 9 i \, a^{2} e^{\left (5 i \, d x + 5 i \, c\right )} + 20 i \, a^{2} e^{\left (3 i \, d x + 3 i \, c\right )} - 15 i \, a^{2} e^{\left (i \, d x + i \, c\right )}\right )} \sqrt {\frac {a}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} \sqrt {\frac {-i \, e^{\left (2 i \, d x + 2 i \, c\right )} + i}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} - 15 \, \sqrt {\frac {32 i \, a^{5}}{d^{2}}} {\left (d e^{\left (6 i \, d x + 6 i \, c\right )} - 3 \, d e^{\left (4 i \, d x + 4 i \, c\right )} + 3 \, d e^{\left (2 i \, d x + 2 i \, c\right )} - d\right )} \log \left (\frac {{\left (4 \, \sqrt {2} {\left (a^{2} e^{\left (2 i \, d x + 2 i \, c\right )} + a^{2}\right )} \sqrt {\frac {a}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} \sqrt {\frac {-i \, e^{\left (2 i \, d x + 2 i \, c\right )} + i}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} + i \, \sqrt {\frac {32 i \, a^{5}}{d^{2}}} d e^{\left (i \, d x + i \, c\right )}\right )} e^{\left (-i \, d x - i \, c\right )}}{4 \, a^{2}}\right ) + 15 \, \sqrt {\frac {32 i \, a^{5}}{d^{2}}} {\left (d e^{\left (6 i \, d x + 6 i \, c\right )} - 3 \, d e^{\left (4 i \, d x + 4 i \, c\right )} + 3 \, d e^{\left (2 i \, d x + 2 i \, c\right )} - d\right )} \log \left (\frac {{\left (4 \, \sqrt {2} {\left (a^{2} e^{\left (2 i \, d x + 2 i \, c\right )} + a^{2}\right )} \sqrt {\frac {a}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} \sqrt {\frac {-i \, e^{\left (2 i \, d x + 2 i \, c\right )} + i}{e^{\left (2 i \, d x + 2 i \, c\right )} + 1}} - i \, \sqrt {\frac {32 i \, a^{5}}{d^{2}}} d e^{\left (i \, d x + i \, c\right )}\right )} e^{\left (-i \, d x - i \, c\right )}}{4 \, a^{2}}\right )}{30 \, {\left (d e^{\left (6 i \, d x + 6 i \, c\right )} - 3 \, d e^{\left (4 i \, d x + 4 i \, c\right )} + 3 \, d e^{\left (2 i \, d x + 2 i \, c\right )} - d\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+a\,\mathrm {tan}\left (c+d\,x\right )\,1{}\mathrm {i}\right )}^{5/2}}{{\mathrm {tan}\left (c+d\,x\right )}^{7/2}} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________